package com.example.stringbufferlogger.VO;

import java.util.List;

/**
 * 分页响应类
 */
public class PageResponse<T> {
    private int pageNum;      // 当前页码
    private int pageSize;     // 每页大小
    private long total;       // 总记录数
    private List<T> list;     // 当前页的数据列表

    public PageResponse() {
    }

    public PageResponse(int pageNum, int pageSize, long total, List<T> list) {
        this.pageNum = pageNum;
        this.pageSize = pageSize;
        this.total = total;
        this.list = list;
    }

    // Getters and Setters
    public int getPageNum() {
        return pageNum;
    }

    public void setPageNum(int pageNum) {
        this.pageNum = pageNum;
    }

    public int getPageSize() {
        return pageSize;
    }

    public void setPageSize(int pageSize) {
        this.pageSize = pageSize;
    }

    public long getTotal() {
        return total;
    }

    public void setTotal(long total) {
        this.total = total;
    }

    public List<T> getList() {
        return list;
    }

    public void setList(List<T> list) {
        this.list = list;
    }
}

